﻿using System;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;

namespace InvestmentIntelligence.DbModel.Models.TradingData
{
    [Table("TradeRequest", Schema = "TradingData")]
    public class TradeRequest
    {
        [Key]
        public int TradeId { get; set; }
        public string FirstName { get; set; }
        public string LastName { get; set; }
        public string Office { get; set; }
        public DateTime RequestDate { get; set; }
        public TradeRequestStatus Status { get; set; }
        public TransactionType Type { get; set; }
        public string Description { get; set; }
        public decimal RequestedQuantity { get; set; }

        public enum TradeRequestStatus : short
        {
            Approved, 
            ApprovedAppeal, 
            Retracted,
            Denied
        }

        public enum TransactionType : short
        {
            Buy,
            Sell,
            SellShort,
            BuyToCover,
            BuyToOpenOption,
            BuyToCloseOption,
            SellToOpenOption,
            SellToCloseOption
        }
    }
}